.class public Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;
.super Lcom/bitauto/autoeasy/BaseActivity;
.source "EvaluatingActivity.java"

# interfaces
.implements Landroid/widget/AdapterView$OnItemClickListener;


# annotations
.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity$downLoadTask;
    }
.end annotation

.annotation system Ldalvik/annotation/Signature;
    value = {
        "Lcom/bitauto/autoeasy/BaseActivity;",
        "Landroid/widget/AdapterView$OnItemClickListener;"
    }
.end annotation


# instance fields
.field private final NEWSID:Ljava/lang/String;

.field private final TITLE:Ljava/lang/String;

.field private list:Ljava/util/ArrayList;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/ArrayList",
            "<",
            "Lcom/bitauto/autoeasy/selectcar/Object/Evaluat;",
            ">;"
        }
    .end annotation
.end field

.field private listView:Landroid/widget/ListView;

.field private tilte:Ljava/lang/String;


# direct methods
.method public constructor <init>()V
    .locals 1

    .prologue
    .line 25
    invoke-direct {p0}, Lcom/bitauto/autoeasy/BaseActivity;-><init>()V

    .line 27
    const-string v0, "title"

    iput-object v0, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->TITLE:Ljava/lang/String;

    .line 33
    const-string v0, "newsid"

    iput-object v0, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->NEWSID:Ljava/lang/String;

    .line 25
    return-void
.end method


# virtual methods
.method public downLoadData()V
    .locals 5

    .prologue
    .line 57
    new-instance v0, Lcom/bitauto/autoeasy/selectcar/Object/EvaluatParser;

    new-instance v1, Ljava/lang/StringBuilder;

    const-string v2, "http://m.bitauto.com/iphoneapi/v2/autotest/?carid="

    invoke-direct {v1, v2}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {p0}, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->getIntent()Landroid/content/Intent;

    move-result-object v2

    const-string v3, "carid"

    const/4 v4, 0x0

    invoke-virtual {v2, v3, v4}, Landroid/content/Intent;->getIntExtra(Ljava/lang/String;I)I

    move-result v2

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    invoke-direct {v0, v1}, Lcom/bitauto/autoeasy/selectcar/Object/EvaluatParser;-><init>(Ljava/lang/String;)V

    .line 58
    .local v0, evaluatParser:Lcom/bitauto/autoeasy/selectcar/Object/EvaluatParser;
    invoke-virtual {v0}, Lcom/bitauto/autoeasy/selectcar/Object/EvaluatParser;->Paser2Object()Ljava/util/ArrayList;

    move-result-object v1

    iput-object v1, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->list:Ljava/util/ArrayList;

    .line 60
    return-void
.end method

.method protected onCreate(Landroid/os/Bundle;)V
    .locals 4
    .parameter "savedInstanceState"

    .prologue
    .line 43
    invoke-super {p0, p1}, Lcom/bitauto/autoeasy/BaseActivity;->onCreate(Landroid/os/Bundle;)V

    .line 45
    invoke-virtual {p0}, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->getIntent()Landroid/content/Intent;

    move-result-object v0

    const-string v1, "title"

    invoke-virtual {v0, v1}, Landroid/content/Intent;->getStringExtra(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v0

    iput-object v0, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->tilte:Ljava/lang/String;

    .line 47
    const v0, 0x7f03002a

    invoke-virtual {p0, v0}, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->setContentView(I)V

    .line 49
    const v0, 0x102000a

    invoke-virtual {p0, v0}, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->findViewById(I)Landroid/view/View;

    move-result-object v0

    check-cast v0, Landroid/widget/ListView;

    iput-object v0, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->listView:Landroid/widget/ListView;

    .line 51
    new-instance v0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity$downLoadTask;

    invoke-direct {v0, p0}, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity$downLoadTask;-><init>(Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;)V

    const/4 v1, 0x1

    new-array v1, v1, [Ljava/lang/String;

    const/4 v2, 0x0

    const-string v3, ""

    aput-object v3, v1, v2

    invoke-virtual {v0, v1}, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity$downLoadTask;->execute([Ljava/lang/Object;)Landroid/os/AsyncTask;

    .line 53
    return-void
.end method

.method public onItemClick(Landroid/widget/AdapterView;Landroid/view/View;IJ)V
    .locals 4
    .parameter
    .parameter "view"
    .parameter "position"
    .parameter "id"
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Landroid/widget/AdapterView",
            "<*>;",
            "Landroid/view/View;",
            "IJ)V"
        }
    .end annotation

    .prologue
    .line 80
    .local p1, parent:Landroid/widget/AdapterView;,"Landroid/widget/AdapterView<*>;"
    iget-object v2, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->list:Ljava/util/ArrayList;

    invoke-virtual {v2, p3}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/bitauto/autoeasy/selectcar/Object/Evaluat;

    .line 81
    .local v0, eva:Lcom/bitauto/autoeasy/selectcar/Object/Evaluat;
    new-instance v1, Landroid/content/Intent;

    const-class v2, Lcom/bitauto/autoeasy/selectcar/EvaluatingDetailActivity;

    invoke-direct {v1, p0, v2}, Landroid/content/Intent;-><init>(Landroid/content/Context;Ljava/lang/Class;)V

    .line 82
    .local v1, intent:Landroid/content/Intent;
    const-string v2, "title"

    iget-object v3, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->tilte:Ljava/lang/String;

    invoke-virtual {v1, v2, v3}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    .line 86
    const-string v2, "newsid"

    invoke-virtual {v0}, Lcom/bitauto/autoeasy/selectcar/Object/Evaluat;->getNewsid()Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v1, v2, v3}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    .line 87
    invoke-virtual {p0, v1}, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->startActivity(Landroid/content/Intent;)V

    .line 89
    return-void
.end method

.method public refreshView()V
    .locals 2

    .prologue
    .line 63
    iget-object v1, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->list:Ljava/util/ArrayList;

    if-eqz v1, :cond_0

    iget-object v1, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->list:Ljava/util/ArrayList;

    invoke-virtual {v1}, Ljava/util/ArrayList;->size()I

    move-result v1

    if-lez v1, :cond_0

    .line 64
    new-instance v0, Lcom/bitauto/autoeasy/selectcar/Adapter/EvaluatListAdapter;

    invoke-direct {v0, p0}, Lcom/bitauto/autoeasy/selectcar/Adapter/EvaluatListAdapter;-><init>(Landroid/app/Activity;)V

    .line 65
    .local v0, adapter:Lcom/bitauto/autoeasy/selectcar/Adapter/EvaluatListAdapter;
    iget-object v1, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->list:Ljava/util/ArrayList;

    invoke-virtual {v0, v1}, Lcom/bitauto/autoeasy/selectcar/Adapter/EvaluatListAdapter;->setList(Ljava/util/ArrayList;)V

    .line 66
    iget-object v1, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->listView:Landroid/widget/ListView;

    invoke-virtual {v0, v1}, Lcom/bitauto/autoeasy/selectcar/Adapter/EvaluatListAdapter;->setListView(Landroid/widget/ListView;)V

    .line 68
    iget-object v1, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->listView:Landroid/widget/ListView;

    invoke-virtual {v1, v0}, Landroid/widget/ListView;->setAdapter(Landroid/widget/ListAdapter;)V

    .line 69
    iget-object v1, p0, Lcom/bitauto/autoeasy/selectcar/EvaluatingActivity;->listView:Landroid/widget/ListView;

    invoke-virtual {v1, p0}, Landroid/widget/ListView;->setOnItemClickListener(Landroid/widget/AdapterView$OnItemClickListener;)V

    .line 74
    .end local v0           #adapter:Lcom/bitauto/autoeasy/selectcar/Adapter/EvaluatListAdapter;
    :cond_0
    return-void
.end method
